import apiUrl from '../base'
import axios from '@/libs/axios'
const messageManage = {
    // 问询回复列表
    questionList(parmes) {
        return axios.post(`${apiUrl.risk}/v1/Question/list`, parmes)
    },
    // 添加业务问询
    questionAdd(parmes) {
        return axios.post(`${apiUrl.risk}/v1/Question/add`, parmes)   
    },
    // 问询回复详情
    questionAnswerDetail(parmes) {
        return axios.get(`${apiUrl.risk}v1/Question/answerDetail?businessType=${parmes.businessType}&objectId=${parmes.objectId}&id=${parmes.id}`, '')   // &projectId=${parmes.projectTeamId}
    },
    // 问询回复详情
    questionAddAnswer(parmes) {
        return axios.post(`${apiUrl.risk}v1/Question/addAnswer`, parmes)
    },
    // 业务问询消息详情列表
    messageDetailList(parmes) {
        return axios.post(`${apiUrl.risk}v1/QuestionMessage/messageDetailList`, parmes)
    },
    // pc端业务问询-各业务类型未处理消息总数
    noReadBusinessTypeCount(parmes) {
        return axios.post(`${apiUrl.risk}v1/QuestionMessage/noReadBusinessTypeCount`, parmes)
    },
    // 业务问询消息状态更新
    messageUpdateStatus(parmes) {
        return axios.post(`${apiUrl.risk}v1/QuestionMessage/updateStatus`, parmes)
    },
    // 业务问询回复更新成已读
    updateAnswerIsRead(parmes) {
        return axios.post(`${apiUrl.risk}/v1/Question/updateAnswerIsRead`, parmes)
    },
    // 人员列表
    searchTreeByProject(projectId) {
        return axios.get(`${apiUrl.risk}v1/OrgTree/tree/searchTreeByProject/${projectId}`, '')
    },
}
export default messageManage